<template>
  <div style="margin-left:2% ;">
    <el-form ref="elForm" :model="formData" :rules="rules" size="medium" label-width="77px"
      label-position="left">
      <el-row gutter="77">
        <div class="row"><div class="test">视频</div></div>
        <el-row gutter="77">
          <el-col :span="10">
            <el-form-item label="视频服务器ip地址" prop="field105">
              <el-input v-model="formData.field105" clearable :style="{width: '100%'}">
              </el-input>
            </el-form-item>
          </el-col>
          <el-col :span="10">
            <el-form-item label="视频服务器TCP端口" prop="field106">
              <el-input v-model="formData.field106" clearable :style="{width: '100%'}">
              </el-input>
            </el-form-item>
          </el-col>
          <el-col :span="10">
            <el-form-item label="视频服务器UDP端口" prop="field105">
              <el-input v-model="formData.field105" clearable :style="{width: '100%'}">
              </el-input>
            </el-form-item>
          </el-col>
          <el-col :span="10">
            <el-form-item label="视频拉流端口" prop="field106">
              <el-input v-model="formData.field106" clearable :style="{width: '100%'}">
              </el-input>
            </el-form-item>
          </el-col>
          <el-col :span="10">
            <el-form-item label="视频服务器TCP端口（外网）" prop="field105">
              <el-input v-model="formData.field105" clearable :style="{width: '100%'}">
              </el-input>
            </el-form-item>
          </el-col>
          <el-col :span="10">
            <el-form-item label="视频服务器UDP端口（外网）" prop="field106">
              <el-input v-model="formData.field106" clearable :style="{width: '100%'}">
              </el-input>
            </el-form-item>
          </el-col>
          <el-col :span="10">
            <el-form-item label="视频拉流端口（外网）" prop="field106">
              <el-input v-model="formData.field106" clearable :style="{width: '100%'}">
              </el-input>
            </el-form-item>
          </el-col>
        </el-row>
      </el-row>
      <el-row gutter="77">
        <div class="row"><div class="test">视频回放</div></div>
        <el-row gutter="77">
          <el-col :span="10">
            <el-form-item label="视频回放专用的TCP端口" prop="field111">
              <el-input v-model="formData.field111" clearable :style="{width: '100%'}">
              </el-input>
            </el-form-item>
          </el-col>
          <el-col :span="10">
            <el-form-item label="对讲端口" prop="field112">
              <el-input v-model="formData.field112" clearable :style="{width: '100%'}">
              </el-input>
            </el-form-item>
          </el-col>
          <el-col :span="10">
            <el-form-item label="809音视频服务端口" prop="field111">
              <el-input v-model="formData.field111" clearable :style="{width: '100%'}">
              </el-input>
            </el-form-item>
          </el-col>
          <el-col :span="10">
            <el-form-item label="广播端口" prop="field112">
              <el-input v-model="formData.field112" clearable :style="{width: '100%'}">
              </el-input>
            </el-form-item>
          </el-col>
          <el-col :span="10">
            <el-form-item label="视频回放专用的TCP端口（外网）" prop="field111">
              <el-input v-model="formData.field111" clearable :style="{width: '100%'}">
              </el-input>
            </el-form-item>
          </el-col>
          <el-col :span="10">
            <el-form-item label="对讲端口（外网）" prop="field112">
              <el-input v-model="formData.field112" clearable :style="{width: '100%'}">
              </el-input>
            </el-form-item>
          </el-col>
          <el-col :span="10">
            <el-form-item label="809音视频服务端口（外网）" prop="field111">
              <el-input v-model="formData.field111" clearable :style="{width: '100%'}">
              </el-input>
            </el-form-item>
          </el-col>
          <el-col :span="10">
            <el-form-item label="广播端口（外网）" prop="field112">
              <el-input v-model="formData.field112" clearable :style="{width: '100%'}">
              </el-input>
            </el-form-item>
          </el-col>
        </el-row>
      </el-row>
      <el-row gutter="77">
        <div class="row"><div class="test">FTP</div></div>
        <el-row gutter="77">
          <el-col :span="10">
            <el-form-item label="FTP服务器IP地址" prop="field115">
              <el-input v-model="formData.field115" clearable :style="{width: '100%'}">
              </el-input>
            </el-form-item>
          </el-col>
          <el-col :span="10">
            <el-form-item label="FTP服务名" prop="field116">
              <el-input v-model="formData.field116" clearable :style="{width: '100%'}">
              </el-input>
            </el-form-item>
          </el-col>
          <el-col :span="10">
            <el-form-item label="FTP服务器端口" prop="field115">
              <el-input v-model="formData.field115" clearable :style="{width: '100%'}">
              </el-input>
            </el-form-item>
          </el-col>
          <el-col :span="10">
            <el-form-item label="FTP密码" prop="field116">
              <el-input v-model="formData.field116" clearable :style="{width: '100%'}">
              </el-input>
            </el-form-item>
          </el-col>
        </el-row>
      </el-row>
      <el-row gutter="77">
        <div class="row"><div class="test">HTTP</div></div>
        <el-row gutter="77">
          <el-col :span="10">
            <el-form-item label="单行文本" prop="field119">
              <el-input v-model="formData.field119" placeholder="请输入单行文本" clearable :style="{width: '100%'}">
              </el-input>
            </el-form-item>
          </el-col>
          <el-col :span="10">
            <el-form-item label="单行文本" prop="field120">
              <el-input v-model="formData.field120" placeholder="请输入单行文本" clearable :style="{width: '100%'}">
              </el-input>
            </el-form-item>
          </el-col>
        </el-row>
      </el-row>
      <el-row gutter="77">
        <div class="row"><div class="test">其他视频</div></div>
        <el-row gutter="77">
          <el-col :span="10">
            <el-form-item label="单行文本" prop="field123">
              <el-input v-model="formData.field123" placeholder="请输入单行文本" clearable :style="{width: '100%'}">
              </el-input>
            </el-form-item>
          </el-col>
          <el-col :span="10">
            <el-form-item label="单行文本" prop="field124">
              <el-input v-model="formData.field124" placeholder="请输入单行文本" clearable :style="{width: '100%'}">
              </el-input>
            </el-form-item>
          </el-col>
        </el-row>
      </el-row>
      <el-form-item size="large">
        <el-button type="primary" @click="submitForm">提交</el-button>
        <el-button @click="resetForm">重置</el-button>
      </el-form-item>
    </el-form>
  </div>
</template>
<script>
export default {
  components: {},
  props: [],
  data() {
    return {
      formData: {
        field105: undefined,
        field106: undefined,
        field111: undefined,
        field112: undefined,
        field115: undefined,
        field116: undefined,
        field119: undefined,
        field120: undefined,
        field123: undefined,
        field124: undefined,
      },
      rules: {
        field105: [{
          required: true,
          message: '请输入单行文本',
          trigger: 'blur'
        }],
        field106: [{
          required: true,
          message: '请输入单行文本',
          trigger: 'blur'
        }],
        field111: [{
          required: true,
          message: '请输入单行文本',
          trigger: 'blur'
        }],
        field112: [{
          required: true,
          message: '请输入单行文本',
          trigger: 'blur'
        }],
        field115: [{
          required: true,
          message: '请输入单行文本',
          trigger: 'blur'
        }],
        field116: [{
          required: true,
          message: '请输入单行文本',
          trigger: 'blur'
        }],
        field119: [{
          required: true,
          message: '请输入单行文本',
          trigger: 'blur'
        }],
        field120: [{
          required: true,
          message: '请输入单行文本',
          trigger: 'blur'
        }],
        field123: [{
          required: true,
          message: '请输入单行文本',
          trigger: 'blur'
        }],
        field124: [{
          required: true,
          message: '请输入单行文本',
          trigger: 'blur'
        }],
      },
    }
  },
  computed: {},
  watch: {},
  created() {},
  mounted() {},
  methods: {
    submitForm() {
      this.$refs['elForm'].validate(valid => {
        if (!valid) return
        // TODO 提交表单
      })
    },
    resetForm() {
      this.$refs['elForm'].resetFields()
    },
  }
}

</script>
<style>
.row{
  width: 95%;
  margin: 10px;
  height: 30px;
  background-color: hsl(187, 66%, 86%);
  border: hwb(187 46% 9%) 1px solid;
  border-radius: 5px;
}
.test{
  margin-left: 10px;
}
</style>
